@using HGShare.Site
@model HGShare.VWModel.UserVModel
@{
    ViewBag.Title = "修改User";
    Layout = "~/Views/Shared/_HContentLayout.cshtml";
}
<div class="wrapper wrapper-content">
    <div class="row">
        <div class="col-sm-12">
            <div class="ibox float-e-margins">
                <div class="ibox-title">
                    <h5>修改User</h5>
                    <div class="ibox-tools">
                        <a class="collapse-link">
                            <i class="fa fa-chevron-up"></i>
                        </a>
                    </div>
                </div>
                <div class="ibox-content">
                    @using(Html.BeginForm("Edit", "Users", FormMethod.Post, new { @class = "form-horizontal",id="addform" }))
                    {

					 					 <div class="form-group">
                            <label class="col-sm-3 control-label">用户ID</label>
                            <div class="col-sm-5">
                                 @Html.TextBoxFor(n => n.Id, new { @class = "form-control", @placeholder = "请输入用户ID" })                            </div>
                            <div class="col-sm-4">
                                @Html.ValidationMessageFor(n => n.Id)
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>

													 <div class="form-group">
                            <label class="col-sm-3 control-label">用户名</label>
                            <div class="col-sm-5">
                                 @Html.TextBoxFor(n => n.Name, new { @class = "form-control", @placeholder = "请输入用户名" })                            </div>
                            <div class="col-sm-4">
                                @Html.ValidationMessageFor(n => n.Name)
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>

													 <div class="form-group">
                            <label class="col-sm-3 control-label">用户昵称</label>
                            <div class="col-sm-5">
                                 @Html.TextBoxFor(n => n.NickName, new { @class = "form-control", @placeholder = "请输入用户昵称" })                            </div>
                            <div class="col-sm-4">
                                @Html.ValidationMessageFor(n => n.NickName)
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>

													 <div class="form-group">
                            <label class="col-sm-3 control-label">密码</label>
                            <div class="col-sm-5">
                                 @Html.TextBoxFor(n => n.Password, new { @class = "form-control", @placeholder = "请输入密码" })                            </div>
                            <div class="col-sm-4">
                                @Html.ValidationMessageFor(n => n.Password)
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>

													 <div class="form-group">
                            <label class="col-sm-3 control-label">角色ID</label>
                            <div class="col-sm-5">
                                 @Html.TextBoxFor(n => n.RoleId, new { @class = "form-control", @placeholder = "请输入角色ID" })                            </div>
                            <div class="col-sm-4">
                                @Html.ValidationMessageFor(n => n.RoleId)
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>

													 <div class="form-group">
                            <label class="col-sm-3 control-label">最后在线时间</label>
                            <div class="col-sm-5">
                                 @Html.TextBoxFor(n => n.OnLineTime, new { @class = "form-control", @placeholder = "请输入最后在线时间" })                            </div>
                            <div class="col-sm-4">
                                @Html.ValidationMessageFor(n => n.OnLineTime)
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>

													 <div class="form-group">
                            <label class="col-sm-3 control-label">最后操作时间</label>
                            <div class="col-sm-5">
                                 @Html.TextBoxFor(n => n.ActionTime, new { @class = "form-control", @placeholder = "请输入最后操作时间" })                            </div>
                            <div class="col-sm-4">
                                @Html.ValidationMessageFor(n => n.ActionTime)
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>

													 <div class="form-group">
                            <label class="col-sm-3 control-label">创建时间</label>
                            <div class="col-sm-5">
                                 @Html.TextBoxFor(n => n.CreateTime, new { @class = "form-control", @placeholder = "请输入创建时间" })                            </div>
                            <div class="col-sm-4">
                                @Html.ValidationMessageFor(n => n.CreateTime)
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>

													 <div class="form-group">
                            <label class="col-sm-3 control-label">头像</label>
                            <div class="col-sm-5">
                                 @Html.TextBoxFor(n => n.Avatar, new { @class = "form-control", @placeholder = "请输入头像" })                            </div>
                            <div class="col-sm-4">
                                @Html.ValidationMessageFor(n => n.Avatar)
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>

													 <div class="form-group">
                            <label class="col-sm-3 control-label">性别 0 未知 1男 2女</label>
                            <div class="col-sm-5">
                                 @Html.TextBoxFor(n => n.Sex, new { @class = "form-control", @placeholder = "请输入性别 0 未知 1男 2女" })                            </div>
                            <div class="col-sm-4">
                                @Html.ValidationMessageFor(n => n.Sex)
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>

													 <div class="form-group">
                            <label class="col-sm-3 control-label">邮箱</label>
                            <div class="col-sm-5">
                                 @Html.TextBoxFor(n => n.Email, new { @class = "form-control", @placeholder = "请输入邮箱" })                            </div>
                            <div class="col-sm-4">
                                @Html.ValidationMessageFor(n => n.Email)
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>

													 <div class="form-group">
                            <label class="col-sm-3 control-label">Email是否激活</label>
                            <div class="col-sm-5">
                                							   <div class="radio radio-info radio-inline">
                                    @Html.RadioButtonFor(n => n.EmailStatus, true, new { id = "EmailStatus1" })
                                    <label for="EmailStatus1">
                                        是
                                    </label>
                                </div>
                                <div class="radio radio-info radio-inline">
                                    @Html.RadioButtonFor(n => n.EmailStatus, false, new { id = "EmailStatus2" })
                                    <label for="EmailStatus2">
                                        否
                                    </label>
                                </div>
							                               </div>
                            <div class="col-sm-4">
                                @Html.ValidationMessageFor(n => n.EmailStatus)
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>

													 <div class="form-group">
                            <label class="col-sm-3 control-label">积分</label>
                            <div class="col-sm-5">
                                 @Html.TextBoxFor(n => n.Score, new { @class = "form-control", @placeholder = "请输入积分" })                            </div>
                            <div class="col-sm-4">
                                @Html.ValidationMessageFor(n => n.Score)
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>

													 <div class="form-group">
                            <label class="col-sm-3 control-label">文章数</label>
                            <div class="col-sm-5">
                                 @Html.TextBoxFor(n => n.ArticleNum, new { @class = "form-control", @placeholder = "请输入文章数" })                            </div>
                            <div class="col-sm-4">
                                @Html.ValidationMessageFor(n => n.ArticleNum)
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>

													 <div class="form-group">
                            <label class="col-sm-3 control-label">回复数</label>
                            <div class="col-sm-5">
                                 @Html.TextBoxFor(n => n.CommentNum, new { @class = "form-control", @placeholder = "请输入回复数" })                            </div>
                            <div class="col-sm-4">
                                @Html.ValidationMessageFor(n => n.CommentNum)
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>

								

                        <div class="form-group">
                            <div class="col-sm-12 col-sm-offset-3">
                                @Html.HiddenFor(n=>n.Id)
                                <button class="btn btn-primary" type="submit" id="submit">保存内容</button>
                                <button class="btn btn-white" type="button" onclick="window.history.back(-1);">取消</button>
                            </div>
                        </div>
                    }
                </div>
            </div>
        </div>
    </div>
</div>
@section script_footer
{
    <!--表单验证-->
    <script src="@Url.StaticFile("~/hplus/js/plugins/validate/jquery.validate.js?v=1.35")"></script>
    <script src="@Url.StaticFile("~/hplus/js/plugins/validate/jquery.validate.unobtrusive.js?v=1.40")"></script>
    <script src="@Url.StaticFile("~/hplus/js/jquery.form.js")"></script>
    <script type="text/javascript">
        ValidataTools.Init({
            backurl: "@Url.Action("Index", "Users")",
            form: $("#addform"),
            submitbtn: $("#submit"),
            btntext: "保存内容",
            tipstype:"修改"
        });
    </script>
}

